<?php

use App\Models\Admin\Admin;
use Illuminate\Database\Seeder;

class AdminTableSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
        $pwd  = Admin::encodePassword(md5('admin'));
        $data = [
            'username' => 'admin',
            'password' => $pwd,
            'nickname' => '超级管理员',
        ];
        Admin::create($data);
    }
}
